import { createApp } from 'vue'
import App from './App.vue'
import { createRouter, createWebHistory} from 'vue-router'

import * as ElementPlusIconsVue from '@element-plus/icons-vue'
import VueAxios from 'vue-axios'
import axios from 'axios'
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import WangEditor from 'wangeditor'
// 
import theCode from './page/theCode.vue'
import zhu from './page/zhu.vue'
import search from './page/search.vue'
import team from './page/team.vue'
import edit from './page/edit.vue'
import login from './page/Login.vue'
const app = createApp(App)
const router = createRouter({
	history: createWebHistory(),
	routes: [
		{path: '/',component: theCode},
        {path:'/theCode',component: theCode ,
            children:[
                {path: 'zhu',component: zhu},
                {path:'search',component:search},
                {path:'edit',component:edit}
            ]
        },
        {path:'/team',component:team },
        {path:'/login',component:login}
		
	]
})
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
    app.component(key, component)
  }
//加载其他模块:
app.use(ElementPlus)
app.use( router )
app.use( VueAxios , axios );
app.mount('#app')
